UserProfileStats.tsx 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. import { CalendarCheck, Flame, ThumbsUp, MessageSquare } from 'lucide-react';
  2. import { UserProfileDto } from '@/types/account/profile';
  3. type Props = {
  4. profile: UserProfileDto;
  5. };
  6. export default function UserProfileStats({ profile }: Props) {
  7. return (
  8. <section className="user-profile__stats" aria-label="회원 활동 통계">
  9. <div className="user-profile__stat">
  10. <ThumbsUp size={20} className="user-profile__stat-icon user-profile__stat-icon--like" strokeWidth={1.75} />
  11. <div className="user-profile__stat-body">
  12. <span className="user-profile__stat-label">받은 좋아요</span>
  13. <span className="user-profile__stat-value">{profile.likeReceivedCount.toLocaleString()}</span>
  14. </div>
  15. </div>
  16. <div className="user-profile__stat">
  17. <MessageSquare size={20} className="user-profile__stat-icon user-profile__stat-icon--comment" strokeWidth={1.75} />
  18. <div className="user-profile__stat-body">
  19. <span className="user-profile__stat-label">투자의견 댓글</span>
  20. <span className="user-profile__stat-value">{profile.commentCount.toLocaleString()}</span>
  21. </div>
  22. </div>
  23. <div className="user-profile__stat">
  24. <CalendarCheck size={20} className="user-profile__stat-icon user-profile__stat-icon--attendance" strokeWidth={1.75} />
  25. <div className="user-profile__stat-body">
  26. <span className="user-profile__stat-label">출석 수</span>
  27. <span className="user-profile__stat-value">{profile.attendanceCount.toLocaleString()}일</span>
  28. </div>
  29. </div>
  30. <div className="user-profile__stat">
  31. <Flame size={20} className="user-profile__stat-icon user-profile__stat-icon--streak" strokeWidth={1.75} />
  32. <div className="user-profile__stat-body">
  33. <span className="user-profile__stat-label">개근 일수</span>
  34. <span className="user-profile__stat-value">{profile.consecutiveDays.toLocaleString()}일</span>
  35. </div>
  36. </div>
  37. </section>
  38. );
  39. }